package io.renren.controller;

import io.renren.annotation.Login;
import io.renren.annotation.LoginUser;
import io.renren.common.entity.XlsUserEntity;
import io.renren.common.utils.Result;
import io.renren.service.XlsCommodityService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import springfox.documentation.annotations.ApiIgnore;


/**
 * 商品表
 *
 * @author Mark sunlightcs@gmail.com
 * @since 1.0.0 2020-04-09
 */
@RestController
@RequestMapping("demo/xlscommodity")
@Api(tags = "商品表")
public class XlsCommodityController {
    @Autowired
    private XlsCommodityService xlsCommodityService;

    @Login
    @GetMapping("userInfo")
    @ApiOperation(value = "获取用户信息", response = XlsUserEntity.class)
    public Result<XlsUserEntity> userInfo(@ApiIgnore @LoginUser XlsUserEntity user) {
        return new Result<XlsUserEntity>().ok(user);
    }
}